package com.cxh.supermarket.business.domain.bo;

import com.cxh.supermarket.common.core.validate.AddGroup;
import com.cxh.supermarket.common.core.validate.EditGroup;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 项目 请求模型
 *
 * @author lly
 * @create 2024/7/29 10:56
 */
@Data
public class ProjectBo {

  /**
   * 主键id
   */
  @NotNull(message = "id不能为空", groups = {EditGroup.class})
  private Long projectId;

  /**
   * 团队id
   */
  private Long teamId;

  /**
   * 项目名称
   */
  @NotBlank(message = "请填写项目名称", groups = {AddGroup.class, EditGroup.class})
  @Length(min = 2, max = 10, message = "项目名称长度范围2~10个字符", groups = {AddGroup.class})
  private String projectName;

  /**
   * 项目编号
   */
  private String projectCode;

  /**
   * 类型1:个人 2：团队
   */
  @NotNull(message = "请填写类型", groups = {AddGroup.class})
  private Integer type;

  /**
   * 状态
   */
  private String status;

  /**
   * 检索类型 全部 0 、我参与 1  、我创建 2
   */
  private Integer retrievalType;

  /**
   * 用户id
   */
  private Long userId;
}
